package com.bifang.module.file.dao.model;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * 文件归集参数表
 *
 * @author shun
 * @since 2023-03-22
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("file_collect")
@Schema(name = "FileCollect", title = "文件归集参数表", description = "文件归集参数表实体类")
public class FileCollect extends Model<FileCollect> {

    private static final long serialVersionUID = 1L;

    @Schema(name = "fileCollectCode", title = "文件归集分类编号")
    @TableId(value="FILE_COLLECT_CODE", type = IdType.INPUT)
    private String fileCollectCode;

    @Schema(name = "collectTitle", title = "归集标题")
    @TableField(value = "COLLECT_TITLE")
    private String collectTitle;

    @Schema(name = "parentCode", title = "父类编号")
    @TableField(value = "PARENT_CODE")
    private String parentCode;

    @Schema(name = "status", title = "有效状态 0 无效 1有效")
    @TableField(value = "STATUS")
    private String status;

    @Schema(name = "archivesCollectCode", title = "对应档案分类编号")
    @TableField(value = "ARCHIVES_COLLECT_CODE")
    private String archivesCollectCode;

    @Schema(name = "expireTime", title = "默认访问过期时间")
    @TableField(value = "EXPIRE_TIME")
    private Date expireTime;

    @Schema(name = "collectParam1", title = "预留字段1")
    @TableField(value = "COLLECT_PARAM1")
    private String collectParam1;

    @Schema(name = "collectParam2", title = "预留字段2")
    @TableField(value = "COLLECT_PARAM2")
    private String collectParam2;

    @Schema(name = "remarks", title = "备注")
    @TableField(value = "REMARKS")
    private String remarks;

    @Schema(name = "createName", title = "创建人")
    @TableField(value = "CREATE_NAME", fill = FieldFill.INSERT, updateStrategy = FieldStrategy.NOT_NULL)
    private String createName;

    @Schema(name = "createTime", title = "创建时间")
    @TableField(value = "CREATE_TIME", fill = FieldFill.INSERT, updateStrategy = FieldStrategy.NOT_NULL)
    private Date createTime;

    @Schema(name = "updateName", title = "更新人")
    @TableField(value = "UPDATE_NAME", fill = FieldFill.INSERT_UPDATE, updateStrategy = FieldStrategy.NOT_NULL)
    private String updateName;

    @Schema(name = "updateTime", title = "更新时间")
    @TableField(value = "UPDATE_TIME", fill = FieldFill.INSERT_UPDATE, updateStrategy = FieldStrategy.NOT_NULL)
    private Date updateTime;

    @Schema(name = "del", title = "逻辑删除标志 0 未删除 1 删除")
    @TableField(value = "DEL", fill = FieldFill.INSERT, updateStrategy = FieldStrategy.NOT_NULL)
    @TableLogic
    private String del;

    @Schema(name = "secrecyLevel", title = "保密级别 1一级 2二级 3三级")
    @TableField(value = "SECRECY_LEVEL")
    private String secrecyLevel;

    @Override
    public Serializable pkVal() {
        return this.fileCollectCode;
    }
}
